Recently, in response to a search request from a user, a search result is provided through a process in which hierarchical-structure data (for example, XML-format data) is converted into table-format data (for example, CSV-format data).
Here, described in detail is about a search process of an information processing apparatus that has XML-format data as search target data. When a search request is received in which XML-format data is set as search target data, the information processing apparatus, as illustrated in FIG. 13 as an example, generates tree-structure data from the entirety of the XML-format data. FIG. 13 is a diagram illustrating the tree structure of the search target data.
The information processing apparatus searches for output items by scanning the tree-structure data. For example, when described using an example illustrated in FIG. 14, the information processing apparatus searches for data corresponding to the output items by scanning the entire tree-structure data in a case where the output items, which are output as a search result, are “document header,” “specification header,” and “the second last value” (see (1) to (20) illustrated in FIG. 14). Then, the information processing apparatus outputs the retrieved data in CSV-format.
In addition, a technology is known in which potential search target data in searching is extracted from the tree-structure data and the extracted potential search target data in tree-structure is stored in a lump.
An example of the related art is Japanese Laid-open Patent Publication No. 2000-348038.
However, according to the above-described technology in which a search is performed by generating the above-described tree, the size of the tree-structure data is large. Accordingly, there are problems in that the amount of memory consumption increases and the time required for the search process is long.
In other words, according to the technology in which a search is performed by generating the above-described tree, the tree-structure data is generated from the entirety of XML-format data. Accordingly, the size of the tree-structure data increases and the amount of memory consumption increases. In addition, since the search is performed by scanning the tree-structure data having a large size, the time required for a search process is long.
In addition, a technology of storing information on part of the tree-structure data in a lump similarly involves problems in that the size of the data is large and thus the memory consumption is large and the processing time is long in the case in which the potential search target data is large in volume.